<include file="public@header" />
</head>
<body>
    <div class="layui-fluid js-check-wrap">
        <div class="layui-card">
            <div class="layui-card-header well">
                <div class="layui-col-xs6">
                    <h3>{:lang('ADMIN_SLIDE_INDEX')}</h3>
                </div>
                <div class="layui-col-xs6 text-right">
                    <if condition="in_array('add', $actions)">
                        <a href="{:url('slide/add')}" class="layui-btn layui-btn-normal">{:lang('ADMIN_SLIDE_ADD')}</a>
                    </if>
                </div>
            </div>

            <div class="layui-card-body">
                <table class="layui-table" >
                    <thead>
                        <tr>
                            <th width="50">ID</th>
                            <th>{:lang('SLIDE')}</th>
                            <th>{:lang('DESCRIPTION')}</th>
                            <th width="180">{:lang('ACTIONS')}</th>
                        </tr>
                    </thead>
                    <tbody>
                        <foreach name="slides" item="vo">
                        <tr>
                            <td>{$vo.id}</td>
                            <td>{$vo.name}</td>
                            <td>{$vo.remark}</td>
                            <td>
                                <if condition="cmf_auth_check(cmf_get_current_admin_id(), 'admin/SlideItem/index')">
                                    <a href="javascript:parent.openIframeLayer('{:url('slideItem/index',array('slide_id'=>$vo['id']))}','{:lang('MANAGE')} {$vo.name} {:lang('PAGE')}',{});" class="layui-btn layui-btn-normal layui-btn-xs">{:lang('MANAGEPAGE')}</a>
                                </if>
                                <if condition="in_array('add', $actions)">
                                    <a href="{:url('slide/edit',array('id'=>$vo['id']))}" class="layui-btn layui-btn-xs">{:lang('EDIT')}</a>
                                </if>
                                <if condition="in_array('delete', $actions)">
                                    <a href="{:url('slide/delete',array('id'=>$vo['id']))}" class="js-ajax-delete layui-btn layui-btn-danger layui-btn-xs">{:lang('DELETE')}</a>
                                </if>
                            </td>
                        </tr>
                        </foreach>
                    </tbody>
                </table>
            </div>
        </div>        
    </div>

<include file="public@footer"/>
